#!/bin/bash

echo "Starting PlantUML Server..."
echo

# 检查Java是否安装
if ! command -v java &> /dev/null; then
    echo "Error: Java is not installed or not in PATH"
    echo "Please install Java 17 or later"
    exit 1
fi

# 检查Maven是否安装
if ! command -v mvn &> /dev/null; then
    echo "Error: Maven is not installed or not in PATH"
    echo "Please install Maven 3.6 or later"
    exit 1
fi

echo "Java and Maven found. Starting server..."
echo

# 编译并运行项目
mvn spring-boot:run 